import 'package:cbec_app/components/base/base_ctr.dart';
import 'package:cbec_app/utils/EventMgr.dart';
import 'package:get/get.dart';

import '../../my/controller/my_ctr.dart';

class PaySuccessController extends BaseController {
  ///支付成功的金额
  String price = '';
  int? paySelected = 0; // 默认值为 0，但仍然是可选的
  @override
  void onInit() {
    super.onInit();
    price = Get.parameters['price']!;
    String? paySelectedString = Get.parameters['paySelected'];
    paySelected = paySelectedString != null ? int.tryParse(paySelectedString) : null;

    MyController contrler = Get.find();
    contrler.onPageRefreshData();
    EventMgr.send(EventType.refreshRaffle);
  }
}
